Integrand size = 24, antiderivative size = 173 \[ \int \cos ^5(c+d x) (a+i a \tan (c+d x))^8 \, dx=-\frac {63 a^8 \text {arctanh}(\sin (c+d x))}{2 d}-\frac {63 i a^8 \sec (c+d x)}{2 d}+\frac {6 i a^3 \cos ^3(c+d x) (a+i a \tan (c+d x))^5}{5 d}-\frac {2 i a \cos ^5(c+d x) (a+i a \tan (c+d x))^7}{5 d}-\frac {42 i a^2 \cos (c+d x) \left (a^2+i a^2 \tan (c+d x)\right )^3}{5 d}-\frac {21 i \sec (c+d x) \left (a^8+i a^8 \tan (c+d x)\right )}{2 d} \]
-63/2*a^8*arctanh(sin(d*x+c))/d-63/2*I*a^8*sec(d*x+c)/d+6/5*I*a^3*cos(d*x+ c)^3*(a+I*a*tan(d*x+c))^5/d-2/5*I*a*cos(d*x+c)^5*(a+I*a*tan(d*x+c))^7/d-42 /5*I*a^2*cos(d*x+c)*(a^2+I*a^2*tan(d*x+c))^3/d-21/2*I*sec(d*x+c)*(a^8+I*a^ 8*tan(d*x+c))/d
Both result and optimal contain complex but leaf count is larger than twice the leaf count of optimal. \(1162\) vs. \(2(173)=346\).
Time = 8.06 (sec) , antiderivative size = 1162, normalized size of antiderivative = 6.72 \[ \int \cos ^5(c+d x) (a+i a \tan (c+d x))^8 \, dx=\frac {63 \cos (8 c) \cos ^8(c+d x) \log \left (\cos \left (\frac {c}{2}+\frac {d x}{2}\right )-\sin \left (\frac {c}{2}+\frac {d x}{2}\right )\right ) (a+i a \tan (c+d x))^8}{2 d (\cos (d x)+i \sin (d x))^8}-\frac {63 \cos (8 c) \cos ^8(c+d x) \log \left (\cos \left (\frac {c}{2}+\frac {d x}{2}\right )+\sin \left (\frac {c}{2}+\frac {d x}{2}\right )\right ) (a+i a \tan (c+d x))^8}{2 d (\cos (d x)+i \sin (d x))^8}+\frac {\cos (5 d x) \cos ^8(c+d x) \left (-\frac {8}{5} i \cos (3 c)-\frac {8}{5} \sin (3 c)\right ) (a+i a \tan (c+d x))^8}{d (\cos (d x)+i \sin (d x))^8}+\frac {\cos (3 d x) \cos ^8(c+d x) (8 i \cos (5 c)+8 \sin (5 c)) (a+i a \tan (c+d x))^8}{d (\cos (d x)+i \sin (d x))^8}+\frac {\cos (d x) \cos ^8(c+d x) (-48 i \cos (7 c)-48 \sin (7 c)) (a+i a \tan (c+d x))^8}{d (\cos (d x)+i \sin (d x))^8}+\frac {\cos ^8(c+d x) \sec (c) (-8 i \cos (8 c)-8 \sin (8 c)) (a+i a \tan (c+d x))^8}{d (\cos (d x)+i \sin (d x))^8}-\frac {63 i \cos ^8(c+d x) \log \left (\cos \left (\frac {c}{2}+\frac {d x}{2}\right )-\sin \left (\frac {c}{2}+\frac {d x}{2}\right )\right ) \sin (8 c) (a+i a \tan (c+d x))^8}{2 d (\cos (d x)+i \sin (d x))^8}+\frac {63 i \cos ^8(c+d x) \log \left (\cos \left (\frac {c}{2}+\frac {d x}{2}\right )+\sin \left (\frac {c}{2}+\frac {d x}{2}\right )\right ) \sin (8 c) (a+i a \tan (c+d x))^8}{2 d (\cos (d x)+i \sin (d x))^8}+\frac {\cos ^8(c+d x) (48 \cos (7 c)-48 i \sin (7 c)) \sin (d x) (a+i a \tan (c+d x))^8}{d (\cos (d x)+i \sin (d x))^8}+\frac {\cos ^8(c+d x) (-8 \cos (5 c)+8 i \sin (5 c)) \sin (3 d x) (a+i a \tan (c+d x))^8}{d (\cos (d x)+i \sin (d x))^8}+\frac {\cos ^8(c+d x) \left (\frac {8}{5} \cos (3 c)-\frac {8}{5} i \sin (3 c)\right ) \sin (5 d x) (a+i a \tan (c+d x))^8}{d (\cos (d x)+i \sin (d x))^8}+\frac {\cos ^8(c+d x) \left (\frac {1}{4} \cos (8 c)-\frac {1}{4} i \sin (8 c)\right ) (a+i a \tan (c+d x))^8}{d (\cos (d x)+i \sin (d x))^8 \left (\cos \left (\frac {c}{2}+\frac {d x}{2}\right )-\sin \left (\frac {c}{2}+\frac {d x}{2}\right )\right )^2}-\frac {i \cos ^8(c+d x) (8 \cos (8 c)-8 i \sin (8 c)) \sin \left (\frac {d x}{2}\right ) (a+i a \tan (c+d x))^8}{d \left (\cos \left (\frac {c}{2}\right )-\sin \left (\frac {c}{2}\right )\right ) (\cos (d x)+i \sin (d x))^8 \left (\cos \left (\frac {c}{2}+\frac {d x}{2}\right )-\sin \left (\frac {c}{2}+\frac {d x}{2}\right )\right )}+\frac {\cos ^8(c+d x) \left (-\frac {1}{4} \cos (8 c)+\frac {1}{4} i \sin (8 c)\right ) (a+i a \tan (c+d x))^8}{d (\cos (d x)+i \sin (d x))^8 \left (\cos \left (\frac {c}{2}+\frac {d x}{2}\right )+\sin \left (\frac {c}{2}+\frac {d x}{2}\right )\right )^2}+\frac {i \cos ^8(c+d x) (8 \cos (8 c)-8 i \sin (8 c)) \sin \left (\frac {d x}{2}\right ) (a+i a \tan (c+d x))^8}{d \left (\cos \left (\frac {c}{2}\right )+\sin \left (\frac {c}{2}\right )\right ) (\cos (d x)+i \sin (d x))^8 \left (\cos \left (\frac {c}{2}+\frac {d x}{2}\right )+\sin \left (\frac {c}{2}+\frac {d x}{2}\right )\right )} \]
(63*Cos[8*c]*Cos[c + d*x]^8*Log[Cos[c/2 + (d*x)/2] - Sin[c/2 + (d*x)/2]]*( a + I*a*Tan[c + d*x])^8)/(2*d*(Cos[d*x] + I*Sin[d*x])^8) - (63*Cos[8*c]*Co s[c + d*x]^8*Log[Cos[c/2 + (d*x)/2] + Sin[c/2 + (d*x)/2]]*(a + I*a*Tan[c + d*x])^8)/(2*d*(Cos[d*x] + I*Sin[d*x])^8) + (Cos[5*d*x]*Cos[c + d*x]^8*((( -8*I)/5)*Cos[3*c] - (8*Sin[3*c])/5)*(a + I*a*Tan[c + d*x])^8)/(d*(Cos[d*x] + I*Sin[d*x])^8) + (Cos[3*d*x]*Cos[c + d*x]^8*((8*I)*Cos[5*c] + 8*Sin[5*c ])*(a + I*a*Tan[c + d*x])^8)/(d*(Cos[d*x] + I*Sin[d*x])^8) + (Cos[d*x]*Cos [c + d*x]^8*((-48*I)*Cos[7*c] - 48*Sin[7*c])*(a + I*a*Tan[c + d*x])^8)/(d* (Cos[d*x] + I*Sin[d*x])^8) + (Cos[c + d*x]^8*Sec[c]*((-8*I)*Cos[8*c] - 8*S in[8*c])*(a + I*a*Tan[c + d*x])^8)/(d*(Cos[d*x] + I*Sin[d*x])^8) - (((63*I )/2)*Cos[c + d*x]^8*Log[Cos[c/2 + (d*x)/2] - Sin[c/2 + (d*x)/2]]*Sin[8*c]* (a + I*a*Tan[c + d*x])^8)/(d*(Cos[d*x] + I*Sin[d*x])^8) + (((63*I)/2)*Cos[ c + d*x]^8*Log[Cos[c/2 + (d*x)/2] + Sin[c/2 + (d*x)/2]]*Sin[8*c]*(a + I*a* Tan[c + d*x])^8)/(d*(Cos[d*x] + I*Sin[d*x])^8) + (Cos[c + d*x]^8*(48*Cos[7 *c] - (48*I)*Sin[7*c])*Sin[d*x]*(a + I*a*Tan[c + d*x])^8)/(d*(Cos[d*x] + I *Sin[d*x])^8) + (Cos[c + d*x]^8*(-8*Cos[5*c] + (8*I)*Sin[5*c])*Sin[3*d*x]* (a + I*a*Tan[c + d*x])^8)/(d*(Cos[d*x] + I*Sin[d*x])^8) + (Cos[c + d*x]^8* ((8*Cos[3*c])/5 - ((8*I)/5)*Sin[3*c])*Sin[5*d*x]*(a + I*a*Tan[c + d*x])^8) /(d*(Cos[d*x] + I*Sin[d*x])^8) + (Cos[c + d*x]^8*(Cos[8*c]/4 - (I/4)*Sin[8 *c])*(a + I*a*Tan[c + d*x])^8)/(d*(Cos[d*x] + I*Sin[d*x])^8*(Cos[c/2 + ...
Time = 0.84 (sec) , antiderivative size = 182, normalized size of antiderivative = 1.05, number of steps used = 12, number of rules used = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.500, Rules used = {3042, 3977, 3042, 3977, 3042, 3977, 3042, 3979, 3042, 3967, 3042, 4257}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \cos ^5(c+d x) (a+i a \tan (c+d x))^8 \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {(a+i a \tan (c+d x))^8}{\sec (c+d x)^5}dx\) |
\(\Big \downarrow \) 3977 |
\(\displaystyle -\frac {9}{5} a^2 \int \cos ^3(c+d x) (i \tan (c+d x) a+a)^6dx-\frac {2 i a \cos ^5(c+d x) (a+i a \tan (c+d x))^7}{5 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {9}{5} a^2 \int \frac {(i \tan (c+d x) a+a)^6}{\sec (c+d x)^3}dx-\frac {2 i a \cos ^5(c+d x) (a+i a \tan (c+d x))^7}{5 d}\) |
\(\Big \downarrow \) 3977 |
\(\displaystyle -\frac {9}{5} a^2 \left (-\frac {7}{3} a^2 \int \cos (c+d x) (i \tan (c+d x) a+a)^4dx-\frac {2 i a \cos ^3(c+d x) (a+i a \tan (c+d x))^5}{3 d}\right )-\frac {2 i a \cos ^5(c+d x) (a+i a \tan (c+d x))^7}{5 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {9}{5} a^2 \left (-\frac {7}{3} a^2 \int \frac {(i \tan (c+d x) a+a)^4}{\sec (c+d x)}dx-\frac {2 i a \cos ^3(c+d x) (a+i a \tan (c+d x))^5}{3 d}\right )-\frac {2 i a \cos ^5(c+d x) (a+i a \tan (c+d x))^7}{5 d}\) |
\(\Big \downarrow \) 3977 |
\(\displaystyle -\frac {9}{5} a^2 \left (-\frac {7}{3} a^2 \left (-5 a^2 \int \sec (c+d x) (i \tan (c+d x) a+a)^2dx-\frac {2 i a \cos (c+d x) (a+i a \tan (c+d x))^3}{d}\right )-\frac {2 i a \cos ^3(c+d x) (a+i a \tan (c+d x))^5}{3 d}\right )-\frac {2 i a \cos ^5(c+d x) (a+i a \tan (c+d x))^7}{5 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {9}{5} a^2 \left (-\frac {7}{3} a^2 \left (-5 a^2 \int \sec (c+d x) (i \tan (c+d x) a+a)^2dx-\frac {2 i a \cos (c+d x) (a+i a \tan (c+d x))^3}{d}\right )-\frac {2 i a \cos ^3(c+d x) (a+i a \tan (c+d x))^5}{3 d}\right )-\frac {2 i a \cos ^5(c+d x) (a+i a \tan (c+d x))^7}{5 d}\) |
\(\Big \downarrow \) 3979 |
\(\displaystyle -\frac {9}{5} a^2 \left (-\frac {7}{3} a^2 \left (-5 a^2 \left (\frac {3}{2} a \int \sec (c+d x) (i \tan (c+d x) a+a)dx+\frac {i \sec (c+d x) \left (a^2+i a^2 \tan (c+d x)\right )}{2 d}\right )-\frac {2 i a \cos (c+d x) (a+i a \tan (c+d x))^3}{d}\right )-\frac {2 i a \cos ^3(c+d x) (a+i a \tan (c+d x))^5}{3 d}\right )-\frac {2 i a \cos ^5(c+d x) (a+i a \tan (c+d x))^7}{5 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {9}{5} a^2 \left (-\frac {7}{3} a^2 \left (-5 a^2 \left (\frac {3}{2} a \int \sec (c+d x) (i \tan (c+d x) a+a)dx+\frac {i \sec (c+d x) \left (a^2+i a^2 \tan (c+d x)\right )}{2 d}\right )-\frac {2 i a \cos (c+d x) (a+i a \tan (c+d x))^3}{d}\right )-\frac {2 i a \cos ^3(c+d x) (a+i a \tan (c+d x))^5}{3 d}\right )-\frac {2 i a \cos ^5(c+d x) (a+i a \tan (c+d x))^7}{5 d}\) |
\(\Big \downarrow \) 3967 |
\(\displaystyle -\frac {9}{5} a^2 \left (-\frac {7}{3} a^2 \left (-5 a^2 \left (\frac {3}{2} a \left (a \int \sec (c+d x)dx+\frac {i a \sec (c+d x)}{d}\right )+\frac {i \sec (c+d x) \left (a^2+i a^2 \tan (c+d x)\right )}{2 d}\right )-\frac {2 i a \cos (c+d x) (a+i a \tan (c+d x))^3}{d}\right )-\frac {2 i a \cos ^3(c+d x) (a+i a \tan (c+d x))^5}{3 d}\right )-\frac {2 i a \cos ^5(c+d x) (a+i a \tan (c+d x))^7}{5 d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {9}{5} a^2 \left (-\frac {7}{3} a^2 \left (-5 a^2 \left (\frac {3}{2} a \left (a \int \csc \left (c+d x+\frac {\pi }{2}\right )dx+\frac {i a \sec (c+d x)}{d}\right )+\frac {i \sec (c+d x) \left (a^2+i a^2 \tan (c+d x)\right )}{2 d}\right )-\frac {2 i a \cos (c+d x) (a+i a \tan (c+d x))^3}{d}\right )-\frac {2 i a \cos ^3(c+d x) (a+i a \tan (c+d x))^5}{3 d}\right )-\frac {2 i a \cos ^5(c+d x) (a+i a \tan (c+d x))^7}{5 d}\) |
\(\Big \downarrow \) 4257 |
\(\displaystyle -\frac {9}{5} a^2 \left (-\frac {7}{3} a^2 \left (-5 a^2 \left (\frac {i \sec (c+d x) \left (a^2+i a^2 \tan (c+d x)\right )}{2 d}+\frac {3}{2} a \left (\frac {a \text {arctanh}(\sin (c+d x))}{d}+\frac {i a \sec (c+d x)}{d}\right )\right )-\frac {2 i a \cos (c+d x) (a+i a \tan (c+d x))^3}{d}\right )-\frac {2 i a \cos ^3(c+d x) (a+i a \tan (c+d x))^5}{3 d}\right )-\frac {2 i a \cos ^5(c+d x) (a+i a \tan (c+d x))^7}{5 d}\) |
(((-2*I)/5)*a*Cos[c + d*x]^5*(a + I*a*Tan[c + d*x])^7)/d - (9*a^2*((((-2*I )/3)*a*Cos[c + d*x]^3*(a + I*a*Tan[c + d*x])^5)/d - (7*a^2*(((-2*I)*a*Cos[ c + d*x]*(a + I*a*Tan[c + d*x])^3)/d - 5*a^2*((3*a*((a*ArcTanh[Sin[c + d*x ]])/d + (I*a*Sec[c + d*x])/d))/2 + ((I/2)*Sec[c + d*x]*(a^2 + I*a^2*Tan[c + d*x]))/d)))/3))/5
3.1.93.3.1 Defintions of rubi rules used
Int[((d_.)*sec[(e_.) + (f_.)*(x_)])^(m_.)*((a_) + (b_.)*tan[(e_.) + (f_.)*( x_)]), x_Symbol] :> Simp[b*((d*Sec[e + f*x])^m/(f*m)), x] + Simp[a Int[(d *Sec[e + f*x])^m, x], x] /; FreeQ[{a, b, d, e, f, m}, x] && (IntegerQ[2*m] || NeQ[a^2 + b^2, 0])
Int[((d_.)*sec[(e_.) + (f_.)*(x_)])^(m_)*((a_) + (b_.)*tan[(e_.) + (f_.)*(x _)])^(n_), x_Symbol] :> Simp[2*b*(d*Sec[e + f*x])^m*((a + b*Tan[e + f*x])^( n - 1)/(f*m)), x] - Simp[b^2*((m + 2*n - 2)/(d^2*m)) Int[(d*Sec[e + f*x]) ^(m + 2)*(a + b*Tan[e + f*x])^(n - 2), x], x] /; FreeQ[{a, b, d, e, f}, x] && EqQ[a^2 + b^2, 0] && GtQ[n, 1] && ((IGtQ[n/2, 0] && ILtQ[m - 1/2, 0]) || (EqQ[n, 2] && LtQ[m, 0]) || (LeQ[m, -1] && GtQ[m + n, 0]) || (ILtQ[m, 0] & & LtQ[m/2 + n - 1, 0] && IntegerQ[n]) || (EqQ[n, 3/2] && EqQ[m, -2^(-1)])) && IntegerQ[2*m]
Int[((d_.)*sec[(e_.) + (f_.)*(x_)])^(m_.)*((a_) + (b_.)*tan[(e_.) + (f_.)*( x_)])^(n_), x_Symbol] :> Simp[b*(d*Sec[e + f*x])^m*((a + b*Tan[e + f*x])^(n - 1)/(f*(m + n - 1))), x] + Simp[a*((m + 2*n - 2)/(m + n - 1)) Int[(d*Se c[e + f*x])^m*(a + b*Tan[e + f*x])^(n - 1), x], x] /; FreeQ[{a, b, d, e, f, m}, x] && EqQ[a^2 + b^2, 0] && GtQ[n, 0] && NeQ[m + n - 1, 0] && IntegersQ [2*m, 2*n]
Int[csc[(c_.) + (d_.)*(x_)], x_Symbol] :> Simp[-ArcTanh[Cos[c + d*x]]/d, x] /; FreeQ[{c, d}, x]
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 321 vs. \(2 (152 ) = 304\).
Time = 2.38 (sec) , antiderivative size = 322, normalized size of antiderivative = 1.86
\[\frac {a^{8} \left (\sin ^{9}\left (d x +c \right )\right )}{2 d \cos \left (d x +c \right )^{2}}+\frac {a^{8} \left (\sin ^{7}\left (d x +c \right )\right )}{2 d}+\frac {203 a^{8} \left (\sin ^{5}\left (d x +c \right )\right )}{10 d}+\frac {21 a^{8} \left (\sin ^{3}\left (d x +c \right )\right )}{2 d}+\frac {283 a^{8} \sin \left (d x +c \right )}{10 d}-\frac {63 a^{8} \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{2 d}-\frac {416 i a^{8} \cos \left (d x +c \right ) \left (\sin ^{2}\left (d x +c \right )\right )}{15 d}+\frac {56 i a^{8} \left (\cos ^{3}\left (d x +c \right )\right ) \left (\sin ^{2}\left (d x +c \right )\right )}{5 d}+\frac {112 i a^{8} \left (\cos ^{3}\left (d x +c \right )\right )}{15 d}-\frac {8 i a^{8} \left (\sin ^{8}\left (d x +c \right )\right )}{d \cos \left (d x +c \right )}-\frac {8 i a^{8} \left (\cos ^{5}\left (d x +c \right )\right )}{5 d}-\frac {104 i a^{8} \cos \left (d x +c \right ) \left (\sin ^{4}\left (d x +c \right )\right )}{5 d}-\frac {832 i a^{8} \cos \left (d x +c \right )}{15 d}+\frac {29 a^{8} \left (\cos ^{4}\left (d x +c \right )\right ) \sin \left (d x +c \right )}{5 d}-\frac {8 a^{8} \left (\cos ^{2}\left (d x +c \right )\right ) \sin \left (d x +c \right )}{5 d}-\frac {8 i a^{8} \cos \left (d x +c \right ) \left (\sin ^{6}\left (d x +c \right )\right )}{d}\]
1/2/d*a^8*sin(d*x+c)^9/cos(d*x+c)^2+1/2*a^8*sin(d*x+c)^7/d+203/10*a^8*sin( d*x+c)^5/d+21/2*a^8*sin(d*x+c)^3/d+283/10*a^8*sin(d*x+c)/d-63/2/d*a^8*ln(s ec(d*x+c)+tan(d*x+c))-416/15*I/d*a^8*cos(d*x+c)*sin(d*x+c)^2+56/5*I/d*a^8* cos(d*x+c)^3*sin(d*x+c)^2+112/15*I/d*a^8*cos(d*x+c)^3-8*I/d*a^8*sin(d*x+c) ^8/cos(d*x+c)-8/5*I/d*a^8*cos(d*x+c)^5-104/5*I/d*a^8*cos(d*x+c)*sin(d*x+c) ^4-832/15*I/d*a^8*cos(d*x+c)+29/5/d*a^8*cos(d*x+c)^4*sin(d*x+c)-8/5/d*a^8* cos(d*x+c)^2*sin(d*x+c)-8*I/d*a^8*cos(d*x+c)*sin(d*x+c)^6
Time = 0.25 (sec) , antiderivative size = 190, normalized size of antiderivative = 1.10 \[ \int \cos ^5(c+d x) (a+i a \tan (c+d x))^8 \, dx=\frac {-16 i \, a^{8} e^{\left (9 i \, d x + 9 i \, c\right )} + 48 i \, a^{8} e^{\left (7 i \, d x + 7 i \, c\right )} - 336 i \, a^{8} e^{\left (5 i \, d x + 5 i \, c\right )} - 1050 i \, a^{8} e^{\left (3 i \, d x + 3 i \, c\right )} - 630 i \, a^{8} e^{\left (i \, d x + i \, c\right )} - 315 \, {\left (a^{8} e^{\left (4 i \, d x + 4 i \, c\right )} + 2 \, a^{8} e^{\left (2 i \, d x + 2 i \, c\right )} + a^{8}\right )} \log \left (e^{\left (i \, d x + i \, c\right )} + i\right ) + 315 \, {\left (a^{8} e^{\left (4 i \, d x + 4 i \, c\right )} + 2 \, a^{8} e^{\left (2 i \, d x + 2 i \, c\right )} + a^{8}\right )} \log \left (e^{\left (i \, d x + i \, c\right )} - i\right )}{10 \, {\left (d e^{\left (4 i \, d x + 4 i \, c\right )} + 2 \, d e^{\left (2 i \, d x + 2 i \, c\right )} + d\right )}} \]
1/10*(-16*I*a^8*e^(9*I*d*x + 9*I*c) + 48*I*a^8*e^(7*I*d*x + 7*I*c) - 336*I *a^8*e^(5*I*d*x + 5*I*c) - 1050*I*a^8*e^(3*I*d*x + 3*I*c) - 630*I*a^8*e^(I *d*x + I*c) - 315*(a^8*e^(4*I*d*x + 4*I*c) + 2*a^8*e^(2*I*d*x + 2*I*c) + a ^8)*log(e^(I*d*x + I*c) + I) + 315*(a^8*e^(4*I*d*x + 4*I*c) + 2*a^8*e^(2*I *d*x + 2*I*c) + a^8)*log(e^(I*d*x + I*c) - I))/(d*e^(4*I*d*x + 4*I*c) + 2* d*e^(2*I*d*x + 2*I*c) + d)
Time = 0.45 (sec) , antiderivative size = 235, normalized size of antiderivative = 1.36 \[ \int \cos ^5(c+d x) (a+i a \tan (c+d x))^8 \, dx=\frac {63 a^{8} \left (\frac {\log {\left (e^{i d x} - i e^{- i c} \right )}}{2} - \frac {\log {\left (e^{i d x} + i e^{- i c} \right )}}{2}\right )}{d} + \frac {- 17 i a^{8} e^{3 i c} e^{3 i d x} - 15 i a^{8} e^{i c} e^{i d x}}{d e^{4 i c} e^{4 i d x} + 2 d e^{2 i c} e^{2 i d x} + d} + \begin {cases} \frac {- 8 i a^{8} d^{2} e^{5 i c} e^{5 i d x} + 40 i a^{8} d^{2} e^{3 i c} e^{3 i d x} - 240 i a^{8} d^{2} e^{i c} e^{i d x}}{5 d^{3}} & \text {for}\: d^{3} \neq 0 \\x \left (8 a^{8} e^{5 i c} - 24 a^{8} e^{3 i c} + 48 a^{8} e^{i c}\right ) & \text {otherwise} \end {cases} \]
63*a**8*(log(exp(I*d*x) - I*exp(-I*c))/2 - log(exp(I*d*x) + I*exp(-I*c))/2 )/d + (-17*I*a**8*exp(3*I*c)*exp(3*I*d*x) - 15*I*a**8*exp(I*c)*exp(I*d*x)) /(d*exp(4*I*c)*exp(4*I*d*x) + 2*d*exp(2*I*c)*exp(2*I*d*x) + d) + Piecewise (((-8*I*a**8*d**2*exp(5*I*c)*exp(5*I*d*x) + 40*I*a**8*d**2*exp(3*I*c)*exp( 3*I*d*x) - 240*I*a**8*d**2*exp(I*c)*exp(I*d*x))/(5*d**3), Ne(d**3, 0)), (x *(8*a**8*exp(5*I*c) - 24*a**8*exp(3*I*c) + 48*a**8*exp(I*c)), True))
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 326 vs. \(2 (143) = 286\).
Time = 0.28 (sec) , antiderivative size = 326, normalized size of antiderivative = 1.88 \[ \int \cos ^5(c+d x) (a+i a \tan (c+d x))^8 \, dx=-\frac {96 i \, a^{8} \cos \left (d x + c\right )^{5} - 840 \, a^{8} \sin \left (d x + c\right )^{5} + 224 i \, {\left (3 \, \cos \left (d x + c\right )^{5} - 5 \, \cos \left (d x + c\right )^{3}\right )} a^{8} + 224 i \, {\left (3 \, \cos \left (d x + c\right )^{5} - 10 \, \cos \left (d x + c\right )^{3} + 15 \, \cos \left (d x + c\right )\right )} a^{8} + 96 i \, {\left (\cos \left (d x + c\right )^{5} - 5 \, \cos \left (d x + c\right )^{3} + \frac {5}{\cos \left (d x + c\right )} + 15 \, \cos \left (d x + c\right )\right )} a^{8} - {\left (12 \, \sin \left (d x + c\right )^{5} + 40 \, \sin \left (d x + c\right )^{3} - \frac {30 \, \sin \left (d x + c\right )}{\sin \left (d x + c\right )^{2} - 1} - 105 \, \log \left (\sin \left (d x + c\right ) + 1\right ) + 105 \, \log \left (\sin \left (d x + c\right ) - 1\right ) + 180 \, \sin \left (d x + c\right )\right )} a^{8} - 56 \, {\left (6 \, \sin \left (d x + c\right )^{5} + 10 \, \sin \left (d x + c\right )^{3} - 15 \, \log \left (\sin \left (d x + c\right ) + 1\right ) + 15 \, \log \left (\sin \left (d x + c\right ) - 1\right ) + 30 \, \sin \left (d x + c\right )\right )} a^{8} - 112 \, {\left (3 \, \sin \left (d x + c\right )^{5} - 5 \, \sin \left (d x + c\right )^{3}\right )} a^{8} - 4 \, {\left (3 \, \sin \left (d x + c\right )^{5} - 10 \, \sin \left (d x + c\right )^{3} + 15 \, \sin \left (d x + c\right )\right )} a^{8}}{60 \, d} \]
-1/60*(96*I*a^8*cos(d*x + c)^5 - 840*a^8*sin(d*x + c)^5 + 224*I*(3*cos(d*x + c)^5 - 5*cos(d*x + c)^3)*a^8 + 224*I*(3*cos(d*x + c)^5 - 10*cos(d*x + c )^3 + 15*cos(d*x + c))*a^8 + 96*I*(cos(d*x + c)^5 - 5*cos(d*x + c)^3 + 5/c os(d*x + c) + 15*cos(d*x + c))*a^8 - (12*sin(d*x + c)^5 + 40*sin(d*x + c)^ 3 - 30*sin(d*x + c)/(sin(d*x + c)^2 - 1) - 105*log(sin(d*x + c) + 1) + 105 *log(sin(d*x + c) - 1) + 180*sin(d*x + c))*a^8 - 56*(6*sin(d*x + c)^5 + 10 *sin(d*x + c)^3 - 15*log(sin(d*x + c) + 1) + 15*log(sin(d*x + c) - 1) + 30 *sin(d*x + c))*a^8 - 112*(3*sin(d*x + c)^5 - 5*sin(d*x + c)^3)*a^8 - 4*(3* sin(d*x + c)^5 - 10*sin(d*x + c)^3 + 15*sin(d*x + c))*a^8)/d
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 2849 vs. \(2 (143) = 286\).
Time = 1.42 (sec) , antiderivative size = 2849, normalized size of antiderivative = 16.47 \[ \int \cos ^5(c+d x) (a+i a \tan (c+d x))^8 \, dx=\text {Too large to display} \]
1/655360*(42021645*a^8*e^(28*I*d*x + 14*I*c)*log(I*e^(I*d*x + I*c) + 1) + 588303030*a^8*e^(26*I*d*x + 12*I*c)*log(I*e^(I*d*x + I*c) + 1) + 382396969 5*a^8*e^(24*I*d*x + 10*I*c)*log(I*e^(I*d*x + I*c) + 1) + 15295878780*a^8*e ^(22*I*d*x + 8*I*c)*log(I*e^(I*d*x + I*c) + 1) + 42063666645*a^8*e^(20*I*d *x + 6*I*c)*log(I*e^(I*d*x + I*c) + 1) + 84127333290*a^8*e^(18*I*d*x + 4*I *c)*log(I*e^(I*d*x + I*c) + 1) + 126190999935*a^8*e^(16*I*d*x + 2*I*c)*log (I*e^(I*d*x + I*c) + 1) + 126190999935*a^8*e^(12*I*d*x - 2*I*c)*log(I*e^(I *d*x + I*c) + 1) + 84127333290*a^8*e^(10*I*d*x - 4*I*c)*log(I*e^(I*d*x + I *c) + 1) + 42063666645*a^8*e^(8*I*d*x - 6*I*c)*log(I*e^(I*d*x + I*c) + 1) + 15295878780*a^8*e^(6*I*d*x - 8*I*c)*log(I*e^(I*d*x + I*c) + 1) + 3823969 695*a^8*e^(4*I*d*x - 10*I*c)*log(I*e^(I*d*x + I*c) + 1) + 588303030*a^8*e^ (2*I*d*x - 12*I*c)*log(I*e^(I*d*x + I*c) + 1) + 144218285640*a^8*e^(14*I*d *x)*log(I*e^(I*d*x + I*c) + 1) + 42021645*a^8*e^(-14*I*c)*log(I*e^(I*d*x + I*c) + 1) + 21376575*a^8*e^(28*I*d*x + 14*I*c)*log(I*e^(I*d*x + I*c) - 1) + 299272050*a^8*e^(26*I*d*x + 12*I*c)*log(I*e^(I*d*x + I*c) - 1) + 194526 8325*a^8*e^(24*I*d*x + 10*I*c)*log(I*e^(I*d*x + I*c) - 1) + 7781073300*a^8 *e^(22*I*d*x + 8*I*c)*log(I*e^(I*d*x + I*c) - 1) + 21397951575*a^8*e^(20*I *d*x + 6*I*c)*log(I*e^(I*d*x + I*c) - 1) + 42795903150*a^8*e^(18*I*d*x + 4 *I*c)*log(I*e^(I*d*x + I*c) - 1) + 64193854725*a^8*e^(16*I*d*x + 2*I*c)*lo g(I*e^(I*d*x + I*c) - 1) + 64193854725*a^8*e^(12*I*d*x - 2*I*c)*log(I*e...
Time = 8.58 (sec) , antiderivative size = 281, normalized size of antiderivative = 1.62 \[ \int \cos ^5(c+d x) (a+i a \tan (c+d x))^8 \, dx=-\frac {63\,a^8\,\mathrm {atanh}\left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )}{d}+\frac {65\,a^8\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^8+a^8\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^7\,309{}\mathrm {i}-761\,a^8\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6-a^8\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^5\,1109{}\mathrm {i}+\frac {7351\,a^8\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4}{5}+a^8\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3\,1223{}\mathrm {i}-\frac {4407\,a^8\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2}{5}-a^8\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\,431{}\mathrm {i}+\frac {496\,a^8}{5}}{d\,\left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^9+{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^8\,5{}\mathrm {i}-12\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^7-{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6\,20{}\mathrm {i}+26\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^5+{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4\,26{}\mathrm {i}-20\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3-{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2\,12{}\mathrm {i}+5\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )+1{}\mathrm {i}\right )} \]
(a^8*tan(c/2 + (d*x)/2)^3*1223i - (4407*a^8*tan(c/2 + (d*x)/2)^2)/5 + (735 1*a^8*tan(c/2 + (d*x)/2)^4)/5 - a^8*tan(c/2 + (d*x)/2)^5*1109i - 761*a^8*t an(c/2 + (d*x)/2)^6 + a^8*tan(c/2 + (d*x)/2)^7*309i + 65*a^8*tan(c/2 + (d* x)/2)^8 + (496*a^8)/5 - a^8*tan(c/2 + (d*x)/2)*431i)/(d*(5*tan(c/2 + (d*x) /2) - tan(c/2 + (d*x)/2)^2*12i - 20*tan(c/2 + (d*x)/2)^3 + tan(c/2 + (d*x) /2)^4*26i + 26*tan(c/2 + (d*x)/2)^5 - tan(c/2 + (d*x)/2)^6*20i - 12*tan(c/ 2 + (d*x)/2)^7 + tan(c/2 + (d*x)/2)^8*5i + tan(c/2 + (d*x)/2)^9 + 1i)) - ( 63*a^8*atanh(tan(c/2 + (d*x)/2)))/d